package com.message.tcp.ip.ui.member;

import java.awt.BorderLayout;
import java.awt.FlowLayout;

import javax.swing.JButton;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTable;
import javax.swing.table.DefaultTableModel;

public class KeyManagementPanel extends JPanel {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private JPanel menuPanel;
	private JButton add;
	private JButton update;
	private JButton delete;
	private JScrollPane scrollPane;
	private JTable keyTable;
	public KeyManagementPanel(){
		menuPanel = new JPanel();
		add = new JButton("add");
		update = new JButton("update");
		delete = new JButton("delete");
		menuPanel.setLayout(new FlowLayout());
		menuPanel.add(add);
		menuPanel.add(update);
		menuPanel.add(delete);
		String[] column = {"Id","Key","Checking Value"};
		Object[][] data = null;
		DefaultTableModel model = new DefaultTableModel(data,column);
		keyTable = new JTable(model);
		keyTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
		scrollPane = new JScrollPane(keyTable);
		this.setLayout(new BorderLayout());
		this.add(menuPanel, BorderLayout.NORTH);
		this.add(scrollPane,BorderLayout.CENTER);
	}
}
